import { Component, OnInit, Inject,Renderer2, ChangeDetectionStrategy } from '@angular/core';
import { MAT_DIALOG_DATA, MatDialogRef,  } from '@angular/material'

@Component({
  selector: 'app-new-project',
  templateUrl: './new-project.component.html',
  styleUrls: ['./new-project.component.scss'],
  changeDetection:ChangeDetectionStrategy.OnPush,
})
export class NewProjectComponent implements OnInit {
  title = ''

  constructor(@Inject(MAT_DIALOG_DATA) private data,
              private dialogRef:MatDialogRef<NewProjectComponent>,
              ) { }

  ngOnInit() {
    this.title = this.data.title;

  }
  onClick(){
    // 数据回传
    this.dialogRef.close('close')
  }

}
